let arr = ['a','b','c','d','e'];

console.log("------------for循环--------------");
for (let i = 0;i < arr.length;i ++) {
    console.log(i,"=",arr[i]);
}

console.log("------------for...in--------------");
// for in循环出来的是对象的索引的字符串形式
for (let i in arr) {
    console.log(i,"=",arr[i]);
}

// for of循环：循环对象的值
console.log("------------for...of--------------");
for (let v of arr) {
    console.log(v);
}